### Alizade, Dancygier, Ditlmann 
### "National Penalties Reversed"
### Replication Code 
### Table A5
### For questions, contact jalizade@princeton.edu

# empty environment
rm(list = ls())


#setwd("")
setwd("C:/Users/Jey/Dropbox/WZB/NaturalizationExperiment/Submission/JOP/replication_JOP/data")


# load necessary packages
library(readstata13)


# load data set
dat <- read.dta13("data_experimental.dta")


# regression
mod <- glm(e1_response ~ e1_treat_turkish*e1_leftpol + e1_treat_dual*e1_leftpol + e1_treat_benefits*e1_leftpol, dat, family = "binomial")
summary(mod)

# log-likelihood
logLik(mod)

### NOTE: We do not provide the data and the code to replicate column 2 of table A5 due to concerns of identifiability of politicians. ###
